<!doctype html>
<html>
<head>
<meta charset="utf-8">
<title>无标题文档</title>
<link href="__STATIC__/Admin/css/base.css" rel="stylesheet" type="text/css" />
<link href="__STATIC__/Admin/css/right.css" rel="stylesheet" type="text/css">
<link href="__STATIC__/css/page.css" rel="stylesheet" type="text/css">
<script language="JavaScript" src="__STATIC__/js/jquery-2.1.1.min.js"></script>

<script>
$(document).ready(function(){
   $(function(){
      $('.rightinfo tbody tr:odd').addClass('odd')
   });
   $('.but1').click(function(){
	  var userid=$(this).parent().find("input[name='userid']").val();

	  var par = $(this);
		  par.hide();
	     $.post("{:url('ajaxjiesuan')}",{userid:userid},function(res){	
		     if(res.flag ==0){
			     alert('结算成功');
			     location.reload();
			   }else{
				   alert(res.msg);	
				   par.show();	
			   }
		     
		 },'json');  
   });
   
   $('.btnjiesuan').click(function(){
	   location.href = "{:url('jiesuanall')}";
   });
});
function del(){ if(confirm("确定要删除吗？")) {   return true;  }  else  {  return false;  } }
</script>
</head>

<body>
<div class="place"> <span>位置：</span>
  <ul class="placeul">
    <li><a href="{:url('Index/center')}">首页</a></li>
    <li>代理结算</li>
  </ul>
</div>
<div class="rightinfo">
  <div class="tools">
    <ul class="toolbar">
      <li style="background:#FFF; text-indent:1em; border:0">
        <form name="fsoso1" method="post" action="{:url('User/tixian')}">
          用户ID <input name="sci" type="text" class="dfinput" style="width:100px" >
          <input name="sub" class="btn" value="查询" type="submit">
          <a href="{:url('User/count')}"><input class="btn btnjiesuan" value="一键结算" type="button"></a>
        </form>
      </li>
    </ul>
  </div>
  <table class="tablelist">
    <thead>
      <tr>
        <th>ID</th>
        <th>Openid</th>
        <th width="17%">昵称</th>
        <th width="9%">头像</th>
        <th width="15%">未结算</th>
        <th width="17%">时间</th>
          <eq name="sysconfig[cyongjinfa]" value="2">
        <th>操作</th>
        </eq>
      </tr>
    </thead>
    <tbody>
    {volist name="list" id="vo"}
        <tr height="40" align="center">
          <td>{$vo['user_id']}</td>
          <td>{$vo['openid']}</td>
          <td>{$vo['nickname']}</td>
          <td><img src="{$vo['imgurl']}" height="54" width="54"/></td>
          <td>{$vo['money']/100}</td>
          <td>{$vo['create_time']}</td>
          <td>
             <input type="hidden" name="userid" value="{$vo['user_id']}">
            <a href="{:url('User/count',['id'=>$vo['user_id']])}"><input name="button" type="button" class="btn" style="width:100px" value="结算"/></a>
          </td>
        </tr>
    {/volist}
    </tbody>
  </table>
</div>
<div class="pages">
  <a href="{:url('User/tixian')}">首页</a>
  {if($prepage>0)}
  <a href="{:url('User/tixian?page='.$prepage)}">上一页</a>
  {/if}
  
  {if($nextpage>0)}
  <a href="{:url('User/tixian?page='.$nextpage)}">下一页</a>
  {/if}
  
</div>
<div class="pages">
{if($page)}
	<font>共{$page}条数据</font>
	{else}
	<font color='#ff0000'>暂无数据</font>
	{/if}
</div>
</body>
</html>